# Maintaier: Antonio Rojas <arojas@archlinux.org>

pkgname=liborigin
pkgver=3.0.1
pkgrel=1
pkgdesc='A library for reading OriginLab OPJ project files'
arch=(loong64 x86_64)
license=(GPL2)
url='https://sourceforge.net/projects/liborigin/'
depends=(gcc-libs)
makedepends=(cmake)
source=(https://downloads.sourceforge.net/project/liborigin/liborigin/${pkgver%.*}/liborigin-$pkgver.tar.gz)
sha256sums=('7f5f1ef21f45b6b28a51e354ff44302efb22b0a1adf8e651f526d95dbbf68938')

build() {
  cmake -B build -S $pkgname-$pkgver \
    -DCMAKE_INSTALL_PREFIX=/usr
  cmake --build build
}

package() {
  DESTDIR="$pkgdir" cmake --install build
}
